home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 1 / Cream of the Crop 1.iso / CAD / PKEY11_1.ARJ / CTL.LSP < prev    next >
Text File  |  1992-03-14  |  734b  |  23 lines

  1. ;Copy Objects to another layer leave originals where they are
  2. ;
  3. ;                     ********Patrick J. McKee, author********
  4. ;                       ****Copyright 1992, Power Key tm****
  5. ;
  6. (defun C:CTL ()
  7. (setq oer *error* *error* err2)
  8. (setq ss (ssget))
  9. (SETQ UL1(GETSTRING "\nLayer to copy entities to : "))
  10. (setq counter 0)
  11. (prompt "                     COPYING OBJECTS.......")
  12. (PRINC "\n")
  13. (while
  14.   (setq e (ssname ss counter))
  15.   (setq l (cdr (assoc 8 (entget e))))
  16.   (setq S (ssget "X" (list (cons 8 l))))
  17. (progn
  18.   (setvar"cmdecho"0)
  19.   (command "copy" s "" "0,0" "0,0")
  20.   (command "CHANGE" s "" "P" "LA" UL1 ""))
  21.   (setq counter (+ counter 1))
  22.   (setvar"cmdecho"1)
  23.   (princ "\nCOPYING TO LAYER......" )))